<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Cache-Control"
	content="no-cache, no-store, must-revalidate" />
<meta http-equiv="Pragma" content="no-cache" />
<meta http-equiv="Expires" content="0" />
<meta charset="utf-8" name="viewport"
	content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
<meta charset="UTF-8">
<title>个人资料</title>
<link rel="stylesheet" href="http://carowner.yonyouauto.com/fs01/ase/v1/components/new.min.css">
<link rel="stylesheet"
	href="http://carowner.yonyouauto.com/fs01/ase/v1/components/bootstrap/dist/css/bootstrap.min.css">
<link rel="stylesheet"
	href="http://carowner.yonyouauto.com/fs01/ase/v1/components/bootstrapValidator/css/bootstrapValidator.css"
	type="text/css" />
<script type="text/javascript"
	src="http://carowner.yonyouauto.com/fs01/ase/v1/components/jquery2.1.1/jquery.min.js"></script>
<script type="text/javascript" src="http://carowner.yonyouauto.com/fs01/ase/v1/js/common/py.js"></script>
<script type="text/javascript"
	src="http://carowner.yonyouauto.com/fs01/ase/v1/components/bootstrap/dist/js/bootstrap.min.js"></script>

<script type="text/javascript"
	src="http://carowner.yonyouauto.com/fs01/ase/v1/components/hammer/hammer.min.js"></script>
<script type="text/javascript"
	src="http://carowner.yonyouauto.com/fs01/ase/v1/components/hammer/jquery.hammer.js"></script>

<script
	src="http://carowner.yonyouauto.com/fs01/ase/v1/components/bootstrapValidator/js/bootstrapValidator.js"></script>
<script src="http://carowner.yonyouauto.com/fs01/ase/v1/components/picker/iscroll.js"></script>
<script src="http://carowner.yonyouauto.com/fs01/ase/v1/components/picker/iosSelect.js"></script>

<script type="text/javascript" src="http://carowner.yonyouauto.com/fs01/ase/v1/js/common/common.js"></script>

<script type="text/javascript"
	src="http://api.map.baidu.com/api?v=2.0&ak=6WLRtwjdIPrXW5FaNIsgdZG038pLb84Z"></script>

<script type="text/javascript" src="http://carowner.yonyouauto.com/fs01/ase/v1/js/common/wechatCommon.js"></script>
<script type="text/javascript"
	src="../../js/homepage/personData.js?t=2018112815"></script>
<link href="http://carowner.yonyouauto.com/fs01/ase/v1/js/homepage/style2.css" rel="stylesheet">
<style>
.product-head h1 {
	font-size: 14px;
	font-family: Arial, Helvetica, sans-serif;
	margin-bottom: 3px;
	margin-left: 3px;
}

.product-head {
	font-size: 12px;
	padding: 4px;
	background-color: #ccc;
	width: 235px;
}

.filterform input {
	font-size: 15px;
	padding: 3px;
	border: 1px solid #999;
}

li {
	padding: 0;
	margin: 3px;
	list-style: none;
	width: 100%;
}

li a {
	color: #000;
	font-family: Arial, Helvetica, sans-serif;
	font-size: 11px
}

ul {
	margin: 0;
	padding: 0;
}

.clear {
	clear: both;
}

body {
	background-color: #f6f6f6;
}

a {
	text-decoration: none;
	color: #000;
}

.fatherDiv {
	width: 100%;
	height: 50px;
}
</style>
<link rel="stylesheet" href="http://carowner.yonyouauto.com/fs01/ase/v1/components/picker/iosSelect.css"
	type="text/css" />
</head>
<body>
	<input type="hidden" id="salesConsultantId" name="salesConsultantId"
		value="">
	<input type="hidden" id="salesConsultantPhone"
		name="salesConsultantPhone" value="">
	<input class="hidden" id="carOwnerId" value="">
	<input class="hidden" id="sex" value="">
	<input class="hidden" id="marriage" value="">
	<input class="hidden" id="userId" value="">
	<input class="hidden" id="birthday" value="">
	<input class="hidden" id="potentialUserId" value="">
	<input class="hidden" id="cityCode" value="">
	<input class="hidden" id="provinceCode" value="">
	<input class="hidden" id="dealerCode" name="dealerCode" value="">
	<div id="myTabContent" class="tab-content">
		<img id="headImg" src="http://carowner.yonyouauto.com/fs01/ase/v1/images/GQ/d4.png" style="width: 100%; display:none;">
		<div id="mainDiv">
			<div class="list-group" style="padding: 10px 0 0 0;">
				<div class="list-group-item">
					<div class="row ">
						<div class="col-md-3 col-xs-3 col-sm-3">
							<p style="padding: 15px 0 0 10px;">头像</p>
						</div>
						<div class="col-md-6 col-xs-6 col-sm-6"></div>
						<div class="col-md-3 col-xs-3 col-sm-3">
							<img id="Imgurl" class="img-circle" style="width: 80%;">
						</div>
					</div>
				</div>
			</div>
			<div class="list-group">
				<div class="form-group has-feedback list-group-item fatherDiv">
					<div class="input-group">
						<span class="input-group-addon"
							style="border: 0; background-color: #fff">昵称</span> <input
							type="text" id="userName" name="userName"
							style="border: 0; text-align: right; padding: 6px 37px 6px 40px"
							class="form-control" placeholder="" required
							data-bv-notempty-message="此项必填">
					</div>
				</div>
				 <div class="form-group has-feedback list-group-item fatherDiv">
					<!--  <a class="list-group-item" href="modifyPhone.html" style="border: 0; padding: 6px 10px 6px 10px" onclick="">--> 
					<span id="">绑定手机</span>  <!-- <span class="biaoge-jt"></span><span class="glyphicon glyphicon-chevron-right"
						style="float: right;"> --> </span> <span id="phone"
						style="float: right; padding: 0 10px 0 0;"></span>
					<!-- </a> -->
				</div> 
				<div class="form-group has-feedback list-group-item fatherDiv">
					<a id="" class="list-group-item" onclick="birthPicker(this)"
						style="border: 0; padding: 6px 10px 6px 10px"> <span id="">生日</span>
						<span class="biaoge-jt"></span> <span id="birthdayVal"
						style="float: right; padding: 0 10px 0 0;"></span>
					</a>
				</div>
				<div class="form-group has-feedback list-group-item fatherDiv">
					<a id="selectSex" class="list-group-item"
						style="border: 0; padding: 6px 10px 6px 10px"> <span id="">性别</span>
						<span class="biaoge-jt"></span> <span id="sexVal"
						style="float: right; padding: 0 10px 0 0;"></span>
					</a>
				</div>
				<div class="form-group has-feedback list-group-item fatherDiv">
					<a id="selectMarriage" class="list-group-item"
						style="border: 0; padding: 6px 10px 6px 10px"> <span id="">婚否</span>
						<span class="biaoge-jt"></span> <span id="MarriageVal"
						style="float: right; padding: 0 10px 0 0;"></span>
					</a>
				</div>
				<div class="form-group has-feedback list-group-item fatherDiv">
					<a id="" class="list-group-item" onclick="selectProvince()"
						style="border: 0; padding: 6px 10px 6px 10px"> <span id="">城市</span>
						<span class="biaoge-jt"></span></span> <span id="city"
						style="float: right; padding: 0 10px 0 0;"></span> <span
						id="province" style="float: right; padding: 0 10px 0 0;"></span>
					</a>
				</div>
				<div class="form-group has-feedback list-group-item fatherDiv">
					<div class="input-group">
						<span class="input-group-addon"
							style="border: 0; background-color: #fff">住址</span> <input
							type="text" id="address" name="address"
							style="border: 0; text-align: right; padding: 6px 22px 6px 40px"
							class="form-control" placeholder="" required
							data-bv-notempty-message="此项必填">
					</div>
				</div>
			</div>
			<div class="list-group">
				<div class="form-group has-feedback list-group-item fatherDiv">
					<a id="" class="list-group-item" onclick="selectNowDealer(this)"
						style="border: 0; padding: 6px 10px 6px 10px"> <span id="">首选销售服务店</span>
						<span class="biaoge-jt"></span> <span id="dealerName"
						style="float: right; padding: 0 10px 0 0;"></span>
					</a>
				</div>
				<div class="form-group has-feedback list-group-item fatherDiv">
					<a id="selectSexCounselor" class="list-group-item" href="#"
						style="border: 0; padding: 6px 10px 6px 10px"
						onclick="selectCounselor()"> <span id="">专属服务顾问</span> <span
						class="biaoge-jt"></span> <span id="counselorName"
						style="float: right; padding: 0 10px 0 0;"></span>
					</a>
				</div>
			</div>
			<div class="form-group has-feedback">
				<div class="col-sm-10">
					<button
						style="background-color:#3790f3; font-size: 17px; border-color: transparent;"
						id="immediatelyAppoint" type="button"
						class="btn btn-primary btn-lg btn-block">保存</button>
				</div>
			</div>
		</div>
		<!-- 城市选择-二级页面-省份选择 -->
		<div id="selectProvince" class="list-group container tab-pane fade">
		</div>
		<!-- 城市选择-三级页面 -->
		<div id="selectCity" class="list-group container tab-pane fade">
		</div>
		<!-- 定位当前城市经销商-经销商选择二级页面 -->
		<div id="nowDealerDiv" class="tab-pane fade">
			<script>
				//距离近-距离远
				function near() {
					var aDiv = document.getElementsByTagName('li');
					var oUl = document.getElementById("dealerDiv");
					var arr = [];
					for (var i = 0; i < aDiv.length; i++) {
						arr.push(aDiv[i]); //aDiv是元素的集合，并不是数组，所以不能直接用数组的sort进行排序。
					}
					arr.sort(function(a, b) {
						return a.getAttribute('data-id')
								- b.getAttribute('data-id')
					});
					for (var i = 0; i < arr.length; i++) {
						oUl.appendChild(arr[i]); //将排好序的元素，重新塞到body里面显示。
					}
				}
				//距离远-距离近
				function far() {
					var aDiv = document.getElementsByTagName('li');
					var oUl = document.getElementById("dealerDiv");
					var arr = [];
					for (var i = 0; i < aDiv.length; i++) {
						arr.push(aDiv[i]); //aDiv是元素的集合，并不是数组，所以不能直接用数组的sort进行排序。
					}
					arr.sort(function(a, b) {
						return b.getAttribute('data-id')
								- a.getAttribute('data-id')
					});
					for (var i = 0; i < arr.length; i++) {
						oUl.appendChild(arr[i]); //将排好序的元素，重新塞到body里面显示。
					}
				}
			</script>
			<img src="http://carowner.yonyouauto.com/fs01/ase/v1/images/GQ/d2.png" style="width: 100%;"
				onclick="selectMaintainDealer(this)">
			<form class="filterform" action="#">
				<div>
					<br> <input id="sou" class="filterinput form-control"
						type="text" placeholder="搜索"
						style="width: 80%; margin: 0 auto; font-size: 16px;">
				</div>

				<div class="dropdown">
					<button type="button" class="btn dropdown-toggle"
						id="dropdownMenu1" data-toggle="dropdown"
						style="background-color: #f6f6f6; font-size: 16px;">
						距离 <span class="caret"></span>
					</button>
					<ul style="text-align: center;" id="distance" class="dropdown-menu"
						role="menu" aria-labelledby="dropdownMenu1">

						<a role="presentation" tabindex="-1" onclick="near()"
							style="font-size: 16px;"><span>由近到远</span></a>
						<br>
						<a role="presentation" tabindex="-1" onclick="far()"
							style="font-size: 16px;"><span>由远到近</span></a>

					</ul>
				</div>
				<div id="searchDealer"></div>

				<ul id="list2">
					<li id="KmFirst" data-id="KmFirst">
						<div class="panel panel-default">
							<table style="width: 100%" class="table-condensed">
								<tbody>
									<tr>
										<td style="width: 160px; text-align: left;"><a
											onclick="sureDealer(-1)">
												<p id="nameFirst"
													style="font-family: 黑体; font-size: 16px; color: #000000"></p>
												<p class="hidden" id="shortNameFirst"></p>

										</a></td>
										<td
											style="width: 100px; text-align: center; font-size: 14px; color: #7a7a7a">
											<span>距离：</span><span id="distanceFirst"></span>
										</td>
									</tr>
									<tr>
										<td style="width: 160px; text-align: left;"><span
											id="addrFirst"
											style="font-faminly: 宋体; font-size: 15px; color: #615f5f"></span><br>
											<span id="remarkFirst"
											style="font-faminly: 宋体; font-size: 14px; color: #7a7a7a"></span>
										</td>
										<td style="width: 100px; text-align: center; color: #7a7a7a">
											<a href="" id="Tel"> <span
												class="glyphicon glyphicon-earphone"
												style="color: rgb(255, 0, 23); font-size: 12px;"></span> <span
												style="font-family: 宋体; font-size: 14px; color: #7a7a7a">
													电话</span>
										</a>
										</td>
									</tr>
								</tbody>
							</table>
							<input id="codeFirst" class="hidden" value="">
						</div>
					</li>

					<div id="dealerDiv" class=""></div>
				</ul>
		</div>
		<!-- 经销商选择-三级页面 -->
		<div id="maintainDealerDiv" class="tab-pane fade">
			<img src="http://carowner.yonyouauto.com/fs01/ase/v1/images/GQ/d1.png" style="width: 100%;">
			<form class="filterform" action="#">
				<div>
					<br> <input id="cha" class="filterinput form-control"
						type="text" placeholder="搜索" style="width: 80%; margin: 0 auto;">
				</div>
				<div id="searchCity"></div>
				<div id="dealerMap" class="container">
					<ul id="list1">
						<h3>A</h3>
						<div id="a" style="background-color: #fff"></div>
						<h3>B</h3>
						<div id="b" style="background-color: #fff"></div>
						<h3>C</h3>
						<div id="c" style="background-color: #fff"></div>
						<h3>D</h3>
						<div id="d" style="background-color: #fff"></div>
						<h3>E</h3>
						<div id="e" style="background-color: #fff"></div>
						<h3>F</h3>
						<div id="f" style="background-color: #fff"></div>
						<h3>G</h3>
						<div id="g" style="background-color: #fff"></div>
						<h3>H</h3>
						<div id="h" style="background-color: #fff"></div>
						<h3>I</h3>
						<div id="i" style="background-color: #fff"></div>
						<h3>J</h3>
						<div id="j" style="background-color: #fff"></div>
						<h3>K</h3>
						<div id="k" style="background-color: #fff"></div>
						<h3>L</h3>
						<div id="l" style="background-color: #fff"></div>
						<h3>M</h3>
						<div id="m" style="background-color: #fff"></div>
						<h3>N</h3>
						<div id="n" style="background-color: #fff"></div>
						<h3>O</h3>
						<div id="o" style="background-color: #fff"></div>
						<h3>P</h3>
						<div id="p" style="background-color: #fff"></div>
						<h3>Q</h3>
						<div id="q" style="background-color: #fff"></div>
						<h3>R</h3>
						<div id="r" style="background-color: #fff"></div>
						<h3>S</h3>
						<div id="s" style="background-color: #fff"></div>
						<h3>T</h3>
						<div id="t" style="background-color: #fff"></div>
						<h3>U</h3>
						<div id="u" style="background-color: #fff"></div>
						<h3>V</h3>
						<div id="v" style="background-color: #fff"></div>
						<h3>W</h3>
						<div id="w" style="background-color: #fff"></div>
						<h3>X</h3>
						<div id="x" style="background-color: #fff"></div>
						<h3>Y</h3>
						<div id="y" style="background-color: #fff"></div>
						<h3>Z</h3>
						<div id="z" style="background-color: #fff"></div>
					</ul>
				</div>
		</div>
		<!-- 预约时间-二级页面 -->
		<br>
		<div id="maintainDateSelDiv" class="container tab-pane fade">

			<link rel='stylesheet' href='http://carowner.yonyouauto.com/fs01/ase/v1/js/laydate/laydate.css' />
			<div class='calendar' id='calendar'></div>
			<br>
			<script type='text/javascript' src='http://carowner.yonyouauto.com/fs01/ase/v1/js/laydate/laydate.js'></script>
			<div id="mtDate" style="text-align: center; font-family: 黑体">
				<span>预约到店时间&nbsp;&nbsp;</span> <span id="day" name="day"
					style="color: red"></span>
			</div>
			<br>
			<button style="background-color: #E50014; font-size: 17px;"
				id="timeConfirmBtn" type="button"
				class="btn btn-primary btn-lg btn-block"
				onclick="confirmMaintainTime(this)">确定</button>

		</div>
		<!-- 性别模态框（Modal） -->
		<div class="modal fade" id="sexModal" tabindex="-1" role="dialog"
			aria-labelledby="myModalLabel" aria-hidden="true">
			<div class="modal-dialog">
				<div class="modal-content">
					<div class="modal-body"
						style="text-align: center; font-size: 24px;">
						<input type="radio" id="radio-2-1" name="radio-2-set"
							class="regular-radio" value="0" /><label for="radio-2-1"></label>
						<span>男</span><br /> <input type="radio" id="radio-2-2"
							name="radio-2-set" class="regular-radio" value="1" /><label
							for="radio-2-2"></label> <span>女</span><br />

						<button type="button" class="btn btn-default" data-dismiss="modal"
							onclick="sureSex();">确定</button>
					</div>
				</div>
				<!-- /.modal-content -->
			</div>
			<!-- /.modal-dialog -->
		</div>
		<!-- /.modal -->
		<!-- 婚否模态框（Modal） -->
		<div class="modal fade" id="MarriageModal" tabindex="-1" role="dialog"
			aria-labelledby="myModalLabel" aria-hidden="true">
			<div class="modal-dialog">
				<div class="modal-content">
					<div class="modal-body"
						style="text-align: center; font-size: 24px;">
						<input type="radio" id="radio-3-1" name="radio-3-set" class="regular-radio" value="0" /><label for="radio-3-1"></label>
						<span>单身</span><br /> 
						<input type="radio" id="radio-3-2" name="radio-3-set" class="regular-radio" value="1" /><label for="radio-3-2"></label> 
						<span>已婚</span><br />
						<input type="radio" id="radio-3-3" name="radio-3-set" class="regular-radio" value="2" /><label for="radio-3-3"></label>
						<span>已婚有子女</span><br />

						<button type="button" class="btn btn-default" data-dismiss="modal"
							onclick="sureMarry();">确定</button>
					</div>
				</div>
				<!-- /.modal-content -->
			</div>
			<!-- /.modal-dialog -->
		</div>
		<!-- /.modal -->
		<!-- 顾问模态框（Modal） -->
		<div class="modal fade" id="counselorModal" tabindex="-1"
			role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
			<div class="modal-dialog">
				<div class="modal-content">
					<div class="modal-body" style="text-align: left;">
						<div name="seviceUser" id="seviceUser"></div>
						<!-- <select name="seviceUser" id="seviceUser" class="form-control" placeholder=""
						style="padding: 6px 40px" onchange="addCounseor()">
					</select> -->
					</div>
				</div>
				<!-- /.modal-content -->
				<button type="button" id="conselorBtn" class="close"
					data-dismiss="modal" aria-hidden="true">
			</div>
			<!-- /.modal-dialog -->
		</div>
		<!-- /.modal -->
		<!-- 定位 -->
		<input class="hidden" id="regionName" name="regionName" value="">
		<input class="hidden" id="latitude" name="latitude" value="">
		<input class="hidden" id="longitude" name="longitude" value="">
		<div id="allmap"></div>
		<script type="text/javascript">
			$("#allmap").hide();
			var map = new BMap.Map("allmap");
			var point = new BMap.Point(116.709684, 39.89778);
			map.centerAndZoom(point, 16);
			map.enableScrollWheelZoom();

			var myIcon = new BMap.Icon("myicon.png", new BMap.Size(30, 30), {
				anchor : new BMap.Size(10, 10)
			});

			var marker = new BMap.Marker(point, {
				icon : myIcon
			});
			map.addOverlay(marker);

			var geolocation = new BMap.Geolocation();
			geolocation.getCurrentPosition(function(r) {
				if (this.getStatus() == BMAP_STATUS_SUCCESS) {
					var mk = new BMap.Marker(r.point);
					map.addOverlay(mk);
					//map.panTo(r.point);//地图中心点移到当前位置
					var latCurrent = r.point.lat;
					var lngCurrent = r.point.lng;
					//alert('我的位置：' + latCurrent + ',' + lngCurrent);
					$("#latitude").val(latCurrent);
					$("#longitude").val(lngCurrent);
					//根据经纬度查城市名
					getAddress(lngCurrent, latCurrent);
					//location.href="http://api.map.baidu.com/direction?origin="+latCurrent+","+lngCurrent+"&destination=39.89778,116.709684&mode=driving&region=北京&output=html";

				} else {
					//alert('failed' + this.getStatus());
				}
			}, {
				enableHighAccuracy : true
			})

			map.addOverlay(marker);
			var licontent = "";
			var opts = {
				width : 200,
				height : 80,
			};
			var infoWindow = new BMap.InfoWindow(licontent, opts);
			marker.openInfoWindow(infoWindow);
			marker.addEventListener('click', function() {
				marker.openInfoWindow(infoWindow);
			});

			function getAddress(longitude, latitude) {

				var address;

				//通过baiduMap API获取街道名称
				var map = new BMap.Map("allmap");
				var point = new BMap.Point(longitude, latitude);
				var gc = new BMap.Geocoder();

				gc.getLocation(point, function(rs) {

					var addComp = rs.addressComponents;

					address = addComp.province + ", " + addComp.city + ", "
							+ addComp.district + ", " + addComp.street + ", "
							+ addComp.streetNumber;

					//alert(addComp.city);
					$("#sou").attr('placeholder', "当前城市为：" + addComp.city);
					$("#regionName").val(addComp.city);
				});
				return address;
			}
		</script>
	</div>

</body>
</html>